package com.mingqijia.gassafety.webserver.service;

import com.mingqijia.gassafety.db.entity.HistoryBroken;
import com.baomidou.mybatisplus.extension.service.IService;
import com.mingqijia.gassafety.shared.utils.commonUtils.PageUtil;
import com.mingqijia.gassafety.webserver.request.RecordLogRequest;
import com.mingqijia.gassafety.webserver.response.BrokenLogResponse;
import com.mingqijia.gassafety.webserver.response.HistoryAlarmAndBrokenResponse;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 报警器设备故障记录 服务类
 * </p>
 *
 * @author wanghai
 * @since 2022-08-08
 */
public interface HistoryBrokenService extends IService<HistoryBroken> {

    List<HistoryAlarmAndBrokenResponse> getEffectiveData(Integer customerId);

    /**
     * 查询故障记录v1.0
     * @return
     */
    PageUtil<BrokenLogResponse> list(RecordLogRequest req);
    /**
     * 查询故障记录v2.0
     * @return
     */
    PageUtil<BrokenLogResponse> getList(RecordLogRequest req);

    Map<String, Integer> getConditionList();

    HistoryBroken getImeiLastHistoryBroken(String spId, String imei, Integer consumerId);

}
